// import Axios from 'axios'
import { axios, baseUrl } from '@/libs/util'

export const Login = formData => {
  return axios.post('api/Data/Login', formData)
}
export const ImportPerson = formData => {
  return axios.post('api/Data/ImportPerson', formData)
}
export const ImportPersonRecord = formData => {
  return axios.post('api/Data/ImportPersonRecord', formData)
}
export const SearchPersonGroup =formData => {
  return axios.post('api/Data/SearchPersonGroup',formData)
}
export const SearchPersonGrouphasPage =formData => {
  return axios.post('api/Data/SearchPersonGrouphasPage',formData)
}

export const SearchAreaPersonGroup =formData => {
  return axios.post('api/Data/SearchAreaPersonGroup',formData)
}
export const SearchPerson = formData => {
  return axios.post('api/Data/SearchPerson', formData)
}
export const SearchPersonByApp = formData => {
  return axios.post('api/Data/SearchPersonByApp', formData)
}

export const SearchSavedPerson = formData => {
  return axios.post('api/Data/SearchSavedPerson', formData)
}
export const SearchSavedPersonByApp = formData => {
  return axios.post('api/Data/SearchSavedPersonByApp', formData)
}
export const SearchEmployee = formData => {
  return axios.post('api/Data/SearchEmployee',formData)
}

export const SearchAreaEmployee = () => {
  return axios.post('api/Data/SearchAreaEmployee')
}

export const SearchArea = () => {
  return axios.post('api/Data/SearchArea')
}
export const SearchSignImg = () => {
  return axios.post('api/Data/SearchSignImg')
}
export const DeleteSignImg = formData => {
  return axios.delete('api/Data/DeleteSignImg/'+formData)
}

export const SaveArea = formData => {
  return axios.post('api/Data/SaveArea', formData)
}

export const SaveEmployee = formData => {
  return axios.post('api/Data/SaveEmployee', formData)
}
export const SavePerson = formData => {
  return axios.post('api/Data/SavePerson', formData)
}
export const SavePersonRemark = formData => {
  return axios.post('api/Data/SavePersonRemark', formData)
}

export const GetAssessInfoByPersonId = formData => {
  return axios.get('api/Data/GetAssessInfoByPersonId/'+formData)
}

export const ResetEmployeePwd = formData => {
  return axios.post('api/Data/ResetEmployeePwd/'+ formData)
}
export const DeleteEmployee = formData => {
  return axios.delete('api/Data/DeleteEmployee/'+formData)
}

export const DeletePerson = formData => {
  return axios.delete('api/Data/DeletePerson/'+formData)
}

export const DeletePersonGroup = formData => {
  return axios.delete('api/Data/DeletePersonGroup/'+formData)
}

export const SavedPersonGroup = formData => {
  return axios.post('api/Data/SavedPersonGroup',formData)
}


export const UpdatePwd = formData => {
  return axios.post('api/Data/UpdatePwd', formData)
}
export const GetCount = () => {
  return axios.get('api/Data/GetCount')
}
export const GetWorkCount =formData => {
  return axios.get('api/Data/GetWorkCountbyDate?sdate='+formData.sdate+'&edate='+formData.edate)
}
export const SearchWorkDetail =formData => {
  return axios.post('api/Data/SearchWorkDetail',formData)
}
export const SearchWorkDetailByGroup =formData => {
  return axios.post('api/Data/SearchWorkDetailByGroup',formData)
}

export const SaveActionLog = formData => {
  return axios.post('api/Data/SaveActionLog', formData)
}

export const SearchActionLog = formData => {
  return axios.post('api/Data/SearchActionLog', formData)
}

export const SearchOperateLog = formData => {
  return axios.post('api/Data/SearchOperateLog', formData)
}

export const SearchLoginLog = formData => {
  return axios.post('api/Data/SearchLoginLog', formData)
}
export const saveErrorLogger = formData => {
  return axios.post('api/Data/SaveErrorLog', formData)
}

export const GetErrorLog = () => {
  return axios.get('api/Data/GetErrorLog')
}
export const GetLog = formData => {
  return axios.get('api/Data/GetLog?str='+formData)
}
export const DeleteErrorLog = () => {
  return axios.delete('api/Data/DeleteErrorLog')
}
export const DeleteLog = () => {
  return axios.delete('api/Data/DeleteLog')
}
export const GetAreaYear =() => {
  return axios.get('api/Data/GetAreaYear')
}

export const GetGroupTown =groupid => {
  return axios.get('api/Data/GetGroupTown?groupid='+groupid)
}

export const TransPersonGroup =formData=> {
  return axios.post('api/Data/TransPersonGroup',formData)
}

export const SearchContacts =formData=> {
  return axios.post('api/Data/SearchContacts',formData)
}


export const SaveContacts =formData=> {
  return axios.post('api/Data/SaveContacts',formData)
}


export const DeleteContacts = formData => {
  return axios.delete('api/Data/DeleteContacts/'+formData)
}
 

export const SavePersonGroup = formData => {
  return axios.post('api/Data/SavePersonGroup', formData)
}
export const CancelSavedPersonGroup = id => {
  return axios.post('api/Data/CancelSavedPersonGroup?gid='+id)
}

export const SyncEmplyeeSign = id => {
  return axios.post('api/Data/SyncEmplyeeSign?gid='+id)
}

export const LoginByGid = gid => {
  return axios.post('api/Data/LoginByGid/'+gid)
}


export const SaveCompanySign = formData => {
  return axios.post('api/Data/SaveCompanySign', formData)
}

export const GetCompanySign  = () => {
  return axios.get('api/Data/GetCompanySign ')
}

export const DeleteCompanySign = id => {
  return axios.post('api/Data/DeleteCompanySign?gid='+id)
}

export const GetPersonGroup = id => {
  return axios.get('api/Data/GetPersonGroup?gid='+id)
}
 
